# -*- coding: utf-8 -*-
# @Time    : 2021/8/30 23:46
# @Author  : BrandonGT
# @FileName: 04_PyQt5_QWidget_焦点控制.py

import sys
from PyQt5.QtWidgets import *
from PyQt5.QtCore import *

class Window(QWidget):
    def __init__(self):
        super().__init__()  # 初始化继承的父类内部的__init__
        self.setWindowTitle("的学习")
        self.resize(300, 300)
        self.setup_ui()

    def setup_ui(self):
        le1 = QLineEdit(self)
        le1.move(50, 50)

        le2 = QLineEdit(self)
        le2.move(50, 100)

        le3 = QLineEdit(self)
        le3.move(50, 150)

        # le2.setFocus()
        # le2.clearFocus()
        # le2.setFocusPolicy(Qt.TabFocus)
        # le2.setFocusPolicy(Qt.ClickFocus)
        # le2.setFocusPolicy(Qt.StrongFocus)
        # le2.setFocusPolicy(Qt.NoFocus)



if __name__ == '__main__':
    app = QApplication(sys.argv)
    window = Window()
    window.show()
    sys.exit(app.exec_())